#pragma strict

var projectile : GameObject;
var speed = 100;
//var odotus = 0f;
 
function Update () 
{

//if(Input.GetKey("space")&& odotus <= 0) {

//odotus = 0.5f;



var clone : GameObject = Instantiate (projectile,transform.position,transform.rotation) as GameObject;
clone.rigidbody.velocity.y = -speed;
Destroy(clone,4.0f);
} 

odotus -= Time.deltaTime;

}